Continuation calculus

نویسندگان

  • Bram Geron
  • Herman Geuvers
چکیده

Programs with control are usually modeled using lambda calculus extended with control operators. Instead of modifying lambda calculus, we consider a different model of computation. We introduce continuation calculus, or CC, a deterministic model of computation that is evaluated using only head reduction, and argue that it is suitable for modeling programs with control. It is demonstrated how to define programs, specify them, and prove them correct. This is shown in detail by presenting in CC a list multiplication program that prematurely returns when it encounters a zero. The correctness proof includes termination of the program. In continuation calculus we can model both call-by-name and call-by-value. In addition, call-byname functions can be applied to call-by-value results, and conversely.

برای دانلود رایگان متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Normalization and continuation-passing-style interpretation of simply-typed call-by-need λ-calculus with control

Ariola et al defined a call-by-need λ-calculus with control, together with a sequent calculus presentation of it. They mechanically derive from the sequent calculus presentation a continuationpassing-style transformation simulating the reduction. In this paper we consider the simply-typed version of the calculus and proove its normalization by means of a realizability interpretation. This justi...

متن کامل

On Semantics of a Term Calculus for Classical Logic

The calculus of Curien and Herbelin was introduced to provide the Curry–Howard correspondence for classical logic. The terms of this calculus represent derivations in the sequent calculus proof system and reduction reflects the process of cut-elimination. We investigate some properties of two well-behaved subcalculi of untyped calculus of Curien and Herbelin, closed under the call-by-name and t...

متن کامل

Continuation-Passing Style and Strong Normalisation for Intuitionistic Sequent Calculi

The intuitionistic fragment of the call-by-name version of Curien and Herbelin’s λμμ̃-calculus is isolated and proved strongly normalising by means of an embedding into the simply-typed λ-calculus. Our embedding is a continuation-and-garbage-passing style translation, the inspiring idea coming from Ikeda and Nakazawa’s translation of Parigot’s λμ-calculus. The embedding simulates reductions whil...

متن کامل

Sound Specialization in the Presence of Computational Effects

Moggi's computational lambda calculus c is a well-established model of computation. We deene a two-level version c of the computational lambda calculus and demonstrate that it is an inevitable description for sound specialization. We implement the calculus in terms of a standard two-level lambda calculus via a continuation-passing style transformation. This transformation is sound and complete ...

متن کامل

A decompilation of the pi-calculus and its application to termination

We study the correspondence between a concurrent lambda-calculus in administrative, continuation passing style and a pi-calculus and we derive a termination result for the latter.

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2013